home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / 422mods.zip / PARA0002.422 < prev    next >
Text File  |  1993-01-31  |  3KB  |  94 lines

  1. Para0002.Mod  Puts a color box around Gfiles, counts files
  2. Parapuke #1 @18251
  3. Fri Jan 29 10:03:38 1993
  4.        ╒═════════════════════════════════════════════════════════════════╕
  5.        │ Mod Name: Para0002.mod                   Author: Parapuke etal  │
  6.        │ Difficulty: Cut and paste (easy)         Files : Gfiles.C       │
  7.        │ WWIV Vesion: 4.22                        Date  : 01-29-93       │
  8.        │ Description:  Places a colored box around your Gfiles Section   │
  9.        │               along with a second box around the individual     │
  10.        │               files themselves in each separate G file.         │
  11.        ╘═════════════════════════════════════════════════════════════════╛
  12.  
  13. This mod is a conversion of earlier mods that I have had success with to
  14. mods which are easily usable by the sysops using WWIV v4.22.  This is
  15. primarily a cosmetic modification that Russ Hasslage has asked for that he
  16. saw on my system.  With the addition of the external strings, I was running
  17. into some difficulty on just how to place this so came up with the idea of
  18. simply doing a cut and paste of the entire two voids involved.  In
  19. addition, I have not removed the color codes so change the colors to suit
  20. your needs or desires.....
  21.  
  22. As for who exactly to credit for the original mods, I really couldn't say.
  23. I have had this one since version 4.12 and it continues to work for me...
  24.  
  25. Now, lets begin.
  26.  
  27. Back up your source code!!!
  28.  
  29. watch for wrap around on this one people.  The top bar is long...
  30.  
  31. in Gfiles.C, look for void list_sec (int *......   cut out this and the
  32. next void.  Replace with this.
  33.  
  34. ************************************cut here******************************
  35. void list_sec(int *map, int nmap)
  36. {
  37.   int i,abort;
  38.   char s[81];
  39.  
  40.   abort=0;
  41.   pla("                                                  ",&abort);
  42.   pla("                                                  ",&abort);
  43.   if (okansi()) {
  44.   pla(" 5 Num    7G-Files Sections Available:",&abort);
  45.   pla("3╔════╦═══════════════════════════════════════════════════════════════╗0 ",&abort);
  46.  }
  47.    for (i=0; (i<nmap) && (!abort) && (!hangup); i++) {
  48.      if (okansi()) {
  49.        sprintf(s,"3║2%3d.3║ 1%-62s3║",i+1,gfilesec[map[i]].name);
  50.    pla(s,&abort); }
  51.  }
  52.      if (okansi()) {
  53.   pla("3╚════╩═══════════════════════════════════════════════════════════════╝0 ",&abort);
  54.    }
  55.   nl();
  56. }
  57.  
  58.  
  59. void list_gfiles(gfilerec *g, int nf)
  60. {
  61.   int i,abort;
  62.   char s[81];
  63.  
  64.   abort=0;
  65.   pla("",&abort);
  66.   pla("",&abort);
  67.   if (okansi()) {
  68.   pla("        7G-Files in this Section:",&abort);
  69.   pla("3╔════╦═══════════════════════════════════════════════════════════════╗0 ",&abort);
  70.    }
  71.   if ((nf==0) && (abort==0)) {
  72.     nl();
  73.     pl("None.");
  74.     nl();
  75.   }
  76.   for (i=0; (i<nf) && (!abort) && (!hangup); i++) {
  77.   if (okansi ()) {
  78.     sprintf(s,"3║2%3d.3║ 1%-62s3║0",i+1,g[i].description);
  79.     pla(s,&abort);  }
  80.  
  81.   }
  82.      if (okansi()) {
  83.   pla("3╚════╩═══════════════════════════════════════════════════════════════╝0 ",&abort);
  84.    }
  85.   nl();
  86.   if ((!abort) && (cs())) {
  87.     pl("A. Add G-files");
  88.     pl("D. Delete G-files");
  89.     nl();
  90.   }
  91. }
  92.  
  93. *********************************end cut*********************************
  94.